﻿using Microsoft.Extensions.DependencyInjection;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Infrastructure.Attributes.Ioc
{
    [AttributeUsage(AttributeTargets.Class)]
    public class ComponentAttribute : Attribute
    {
        public ServiceLifetime Lifetime { get; set; }
        public ComponentAttribute() : this(ServiceLifetime.Singleton)
        {
        }
        public ComponentAttribute(ServiceLifetime Lifetime)
        {
            this.Lifetime = Lifetime;
        }

    }
}
